package com.ruoyi.workflow.mapper;


import com.ruoyi.workflow.domain.CompanyApply;
import com.ruoyi.workflow.dto.*;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 单位注册审批记录Mapper接口
 *
 * @author 周志雄
 * @date 2024-03-04
 */
@Mapper
public interface CompanyApplyMapper {

    /**
     * 修改单位注册审批记录
     *
     * @param companyApply 单位注册审批记录
     * @return 结果
     */
    int updateCompanyApply(CompanyApply companyApply);

    /**
     * 开始流程
     * @param companyApply
     */
    int insert(CompanyApply companyApply);

    /**
     * 查看申请详情页，仅获取基础信息
     * @param applyId
     * @return
     */
    CompanyApplyInfoDto queryBasicInfo(String applyId);


    /**
     * 根据业务主键列表去查询对应的申请事件
     * @param businessKeys
     * @param companyApplySearchDto
     * @return
     */
    List<CompanyApplyResDto> selectByBusinessKeyList(@Param("businessKeys") List<String> businessKeys, @Param("searchDto") CompanyApplySearchDto companyApplySearchDto);

    /**
     * 根据ID查询审批信息
     * @param id
     * @return
     */
    CompanyApply selectInfoById(String id);
}
